<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <script>
        //创建一个对象 表示学生的信息 （具体信息可以自定义，需求不限）
        var arr = [{name:"sb",age:22,height:"178cm",weight:"60kg"}
        ,{name:"张三",age:22,height:"175cm",weight:"60kg"}
        ,{name:"李四",age:20,height:"170cm",weight:"50kg"}
        ,{name:"王五",age:23,height:"179cm",weight:"70kg"}
        ,{name:"大胖子",age:21,height:"188cm",weight:"80kg"}
    ];
    for(var i = 0;i < arr.length;i++){
        for(var key in arr[i]){
            console.log(key+"----"+arr[i][key]);
        }
        console.log("<br>")
    };
    </script>
</body>
</html>